package com.yunfei.bo;

import com.ylcaifu.common.auto.util.StringUtil;
import com.yunfei.entity.KfCrmProductAppendixInfoEntity;

/**
 *@tablename KF_CRM_PRODUCT_APPENDIX_INFO
 *@author zhengyunfei
 *@createDate Fri Dec 28 14:07:40 CST 2018
 */


public class KfCrmProductAppendixInfoBo implements java.io.Serializable{
 private String pkId;
 private String productId;
 private String fileName;
 private String uploadAddress;
 private String operator;
 private String visible;
 private String createDate;
 private String remark1;
 private String remark2;
 private String remark3;
 private String trueAddress;
 private String oldName;
 private String field;
 private String order;
/**
     * 更改排序字段
     * @return
     */
public String getField() {
        return field;
}
public void setField(String field) {
        this.field = field;
}
public String getOrder() {
        return order;
}
public void setOrder(String order) {
        this.order = order;
}
 private int curNo;
 public int getCurNo() {
     int value=(curNo-1)*curSize;
     return value;
 }
 public void setCurNo(int curNo) {
     this.curNo = curNo;
 }
 private int curSize;
 public int getCurSize() {
     return curSize;
 }
 public void setCurSize(int curSize) {
     this.curSize = curSize;
 }
 public void setPkId(String pkId){
     this.pkId=pkId;
 }
 public String getPkId(){
     return pkId;
 }
 public void setProductId(String productId){
     this.productId=productId;
 }
 public String getProductId(){
     return productId;
 }
 public void setFileName(String fileName){
     this.fileName=fileName;
 }
 public String getFileName(){
     return fileName;
 }
 public void setUploadAddress(String uploadAddress){
     this.uploadAddress=uploadAddress;
 }
 public String getUploadAddress(){
     return uploadAddress;
 }
 public void setOperator(String operator){
     this.operator=operator;
 }
 public String getOperator(){
     return operator;
 }
 public void setVisible(String visible){
     this.visible=visible;
 }
 public String getVisible(){
     return visible;
 }
 public void setCreateDate(String createDate){
     this.createDate=createDate;
 }
 public String getCreateDate(){
     return createDate;
 }
 public void setRemark1(String remark1){
     this.remark1=remark1;
 }
 public String getRemark1(){
     return remark1;
 }
 public void setRemark2(String remark2){
     this.remark2=remark2;
 }
 public String getRemark2(){
     return remark2;
 }
 public void setRemark3(String remark3){
     this.remark3=remark3;
 }
 public String getRemark3(){
     return remark3;
 }
 public void setTrueAddress(String trueAddress){
     this.trueAddress=trueAddress;
 }
 public String getTrueAddress(){
     return trueAddress;
 }
 public void setOldName(String oldName){
     this.oldName=oldName;
 }
 public String getOldName(){
     return oldName;
 }
 public static KfCrmProductAppendixInfoEntity boToEntity(KfCrmProductAppendixInfoBo bo){
     KfCrmProductAppendixInfoEntity entity=new KfCrmProductAppendixInfoEntity();
     entity.setPkId(bo.getPkId());
     entity.setProductId(bo.getProductId());
     entity.setFileName(bo.getFileName());
     entity.setUploadAddress(bo.getUploadAddress());
     entity.setOperator(bo.getOperator());
     entity.setVisible(bo.getVisible());
     entity.setCreateDate(bo.getCreateDate());
     entity.setRemark1(bo.getRemark1());
     entity.setRemark2(bo.getRemark2());
     entity.setRemark3(bo.getRemark3());
     entity.setTrueAddress(bo.getTrueAddress());
     entity.setOldName(bo.getOldName());
     return entity;
 }
 public static KfCrmProductAppendixInfoBo entityToBo(KfCrmProductAppendixInfoEntity bo){
     KfCrmProductAppendixInfoBo entity=new KfCrmProductAppendixInfoBo();
     entity.setPkId(bo.getPkId());
     entity.setProductId(bo.getProductId());
     entity.setFileName(bo.getFileName());
     entity.setUploadAddress(bo.getUploadAddress());
     entity.setOperator(bo.getOperator());
     entity.setVisible(bo.getVisible());
     entity.setCreateDate(bo.getCreateDate());
     entity.setRemark1(bo.getRemark1());
     entity.setRemark2(bo.getRemark2());
     entity.setRemark3(bo.getRemark3());
     entity.setTrueAddress(bo.getTrueAddress());
     entity.setOldName(bo.getOldName());
     return entity;
 }
 public static String changeFieldColumn(String field){
     String result="";
         if(!StringUtil.isNullOrEmpty(field)){
             if(field.equals("pkId")){
                 result="PK_ID";
             }
             if(field.equals("productId")){
                 result="PRODUCT_ID";
             }
             if(field.equals("fileName")){
                 result="FILE_NAME";
             }
             if(field.equals("uploadAddress")){
                 result="UPLOAD_ADDRESS";
             }
             if(field.equals("operator")){
                 result="OPERATOR";
             }
             if(field.equals("visible")){
                 result="VISIBLE";
             }
             if(field.equals("createDate")){
                 result="CREATE_DATE";
             }
             if(field.equals("remark1")){
                 result="REMARK1";
             }
             if(field.equals("remark2")){
                 result="REMARK2";
             }
             if(field.equals("remark3")){
                 result="REMARK3";
             }
             if(field.equals("trueAddress")){
                 result="TRUE_ADDRESS";
             }
             if(field.equals("oldName")){
                 result="OLD_NAME";
             }
     }
     return result;
 }
}

